package com.dyzx.hbb.modules.sys.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.dyzx.hbb.common.config.MyLambdaQueryWrapper;
import com.dyzx.hbb.modules.sys.entity.SysOrder;
import com.dyzx.hbb.modules.sys.mapper.SysOrderMapper;
import com.dyzx.hbb.modules.sys.service.SysOrderService;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * @author Administrator
 * @description 针对表【sys_order(订单表)】的数据库操作Service实现
 * @createDate 2025-04-22 22:16:03
 */
@Service
public class SysOrderServiceImpl extends ServiceImpl<SysOrderMapper, SysOrder>
        implements SysOrderService {

    @Override
    public Map<String, Object> findByOrderInfo(Long organId) {
        if (organId != null) {
            MyLambdaQueryWrapper<SysOrder> queryWrapper = new MyLambdaQueryWrapper<>();
            queryWrapper.select(SysOrder::getEndDate, SysOrder::getType, SysOrder::getStatus);
            return getMap(queryWrapper);
        }
        return Map.of();
    }
}




